package com.zzxz.practicaltrainingsys.component;

import lombok.Setter;

@Setter
public class WebSocketMessage {

    private String type; // user_message, ai_response, error
    private String content;
    private String sessionId;
    private Long timestamp;

    // Constructors
    public WebSocketMessage() {}

    public WebSocketMessage(String type, String content, String sessionId) {
        this.type = type;
        this.content = content;
        this.sessionId = sessionId;
        this.timestamp = System.currentTimeMillis();
    }

    // Getters and Setters
    public String getType() { return type; }
    public void setType(String type) { this.type = type; }

    public String getContent() { return content; }
    public void setContent(String content) { this.content = content; }

    public String getSessionId() { return sessionId; }
    public void setSessionId(String sessionId) { this.sessionId = sessionId; }

    public Long getTimestamp() { return timestamp; }
    public void setTimestamp(Long timestamp) { this.timestamp = timestamp; }
}